<?php /* Smarty version Smarty-3.1.11, created on 2012-10-08 08:37:20
         compiled from "_templates\home\index.tpl" */ ?>
<?php /*%%SmartyHeaderCode:28189506e8785d53540-79219990%%*/if(!defined('SMARTY_DIR')) exit('no direct access allowed');
$_valid = $_smarty_tpl->decodeProperties(array (
  'file_dependency' => 
  array (
    'c1e7ca0fbf2b8c096902acc151232f3222d8992c' => 
    array (
      0 => '_templates\\home\\index.tpl',
      1 => 1349677401,
      2 => 'file',
    ),
  ),
  'nocache_hash' => '28189506e8785d53540-79219990',
  'function' => 
  array (
  ),
  'version' => 'Smarty-3.1.11',
  'unifunc' => 'content_506e87860a9344_43040546',
  'variables' => 
  array (
    'gameserver' => 0,
    'loginserver' => 0,
    'all_users' => 0,
    'all_players' => 0,
    'online_players' => 0,
    'offline_players' => 0,
    'activated' => 0,
    'banned' => 0,
    'value' => 0,
    'item' => 0,
    'gmvalue' => 0,
  ),
  'has_nocache_code' => false,
),false); /*/%%SmartyHeaderCode%%*/?>
<?php if ($_valid && !is_callable('content_506e87860a9344_43040546')) {function content_506e87860a9344_43040546($_smarty_tpl) {?><h4 class="alert_info"><?php echo $_smarty_tpl->getConfigVariable('welcome');?>
</h4>

<article class="module width_full">
    <header><h3><div style="float:left; width:100px;"><?php echo $_smarty_tpl->getConfigVariable('Stats');?>
</div><div style="float:right; width:150px;"><?php echo $_smarty_tpl->getConfigVariable('gameserver');?>
: <?php echo $_smarty_tpl->tpl_vars['gameserver']->value;?>
</div><div style="float:right; width:150px;"><?php echo $_smarty_tpl->getConfigVariable('loginserver');?>
: <?php echo $_smarty_tpl->tpl_vars['loginserver']->value;?>
</div></h3></header>
    <div class="module_content">
        <article class="stats_overview" style="width:100% !important;">
            <div class="overview_today">
                <p class="overview_type"><?php echo $_smarty_tpl->getConfigVariable('accounts');?>
</p>
                <p class="overview_count"><?php echo $_smarty_tpl->tpl_vars['all_users']->value;?>
</p>
                <p class="overview_type"><?php echo $_smarty_tpl->getConfigVariable('characters');?>
</p>
                <p class="overview_count"><?php echo $_smarty_tpl->tpl_vars['all_players']->value;?>
</p>
            </div>
            <div class="overview_previous">
                <p class="overview_type"><?php echo $_smarty_tpl->getConfigVariable('online');?>
</p>
                <p class="overview_count"><?php echo $_smarty_tpl->tpl_vars['online_players']->value;?>
</p>
                <p class="overview_type"><?php echo $_smarty_tpl->getConfigVariable('offline');?>
</p>
                <p class="overview_count"><?php echo $_smarty_tpl->tpl_vars['offline_players']->value;?>
</p>
            </div>
            <div class="overview_previous">
                <p class="overview_type"><?php echo $_smarty_tpl->getConfigVariable('active');?>
</p>
                <p class="overview_count"><?php echo $_smarty_tpl->tpl_vars['activated']->value;?>
</p>
                <p class="overview_type"><?php echo $_smarty_tpl->getConfigVariable('banned');?>
</p>
                <p class="overview_count"><?php echo $_smarty_tpl->tpl_vars['banned']->value;?>
</p>
            </div>
        </article>
        <div class="clear"></div>
    </div>
</article>
		<article class="module width_full" style="">
			<header><h3 class="tabs_involved" style="text-transform:none; padding-left:10px;" ><?php echo $_smarty_tpl->getConfigVariable('userlogs');?>
</h3>
				<ul class="tabs">
					<li><a href="#tab1"><?php echo $_smarty_tpl->getConfigVariable('donate');?>
</a></li>
					<li><a href="#tab2"><?php echo $_smarty_tpl->getConfigVariable('admin');?>
</a></li>
				</ul>
			</header>

			<div class="tab_container">
				<div id="tab1" class="tab_content">
					<table class="tablesorter" cellspacing="0"> 
						<thead> 
							<tr> 
								<th><?php echo $_smarty_tpl->getConfigVariable('username');?>
</th> 
								<th><?php echo $_smarty_tpl->getConfigVariable('adminname');?>
</th> 
								<th><?php echo $_smarty_tpl->getConfigVariable('timestamp');?>
</th>
								<th><?php echo $_smarty_tpl->getConfigVariable('reason');?>
</th> 
								<th><?php echo $_smarty_tpl->getConfigVariable('coins');?>
</th> 
								<th><?php echo $_smarty_tpl->getConfigVariable('amount');?>
</th> 
							</tr> 
						</thead> 
						<tbody> 
							<?php if (!empty($_smarty_tpl->tpl_vars['value']->value)){?>
							<?php  $_smarty_tpl->tpl_vars['item'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['item']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['value']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['item']->key => $_smarty_tpl->tpl_vars['item']->value){
$_smarty_tpl->tpl_vars['item']->_loop = true;
?>
								<tr>
									<td><a href="index.php?mod=profile&userID=<?php echo $_smarty_tpl->tpl_vars['item']->value['userID'];?>
"><?php echo $_smarty_tpl->tpl_vars['item']->value['username'];?>
</a></td>
									<td><a href="index.php?mod=profile&userID=<?php echo $_smarty_tpl->tpl_vars['item']->value['admin'];?>
"><?php echo $_smarty_tpl->tpl_vars['item']->value['adminname'];?>
</a></td>
									<td><?php echo $_smarty_tpl->tpl_vars['item']->value['timestamp'];?>
</td>
									<td><?php echo $_smarty_tpl->tpl_vars['item']->value['reason'];?>
</td>
									<td><?php echo $_smarty_tpl->tpl_vars['item']->value['coins'];?>
</td>
									<td><?php echo $_smarty_tpl->tpl_vars['item']->value['amount'];?>
</td>
								</tr>
							<?php } ?>
							<?php }else{ ?>
								<tr>
									<td colspan="6"><?php echo $_smarty_tpl->getConfigVariable('nodonation');?>
</td>
								</tr>
							<?php }?>
						</tbody> 
					</table>
				</div>
				<div id="tab2" class="tab_content">
					<div id="tablewrapper">
						<div id="tableheader" style="display:none;">
							<div class="search">
								<select id="columns" onchange="sorter.search('query')">
						  <option value="-1"><?php echo $_smarty_tpl->getConfigVariable('columns');?>
</option>
						  </select>
								<input type="text" id="query" onkeyup="sorter.search('query')" />
							</div>
						<span class="details">
						  <div><?php echo $_smarty_tpl->getConfigVariable('entries');?>
 <span id="startrecord"></span>-<span id="endrecord"></span> <?php echo $_smarty_tpl->getConfigVariable('from');?>
 <span id="totalrecords"></span></div>
						  <div><a href="javascript:sorter.reset()"><?php echo $_smarty_tpl->getConfigVariable('reset');?>
</a></div>
						</span>
					  </div>
					<table cellpadding="0" cellspacing="0" id="table" class="tinytable" style="width:100%;" >
						<thead>
							<tr>
								<th><h3><?php echo $_smarty_tpl->getConfigVariable('username');?>
</h3></th> 
								<th><h3><?php echo $_smarty_tpl->getConfigVariable('timestamp');?>
</h3></th>
								<th><h3><?php echo $_smarty_tpl->getConfigVariable('reason');?>
</h3></th> 
							</tr>
						</thead>
						<tbody>
						<?php if (!empty($_smarty_tpl->tpl_vars['gmvalue']->value)){?>
						<?php  $_smarty_tpl->tpl_vars['item'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['item']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['gmvalue']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['item']->key => $_smarty_tpl->tpl_vars['item']->value){
$_smarty_tpl->tpl_vars['item']->_loop = true;
?>
							<tr>
								<td><a href="index.php?mod=profile&userID=<?php echo $_smarty_tpl->tpl_vars['item']->value['id'];?>
" target="_blank"><?php echo $_smarty_tpl->tpl_vars['item']->value['username'];?>
</a></td>
								<td><?php echo $_smarty_tpl->tpl_vars['item']->value['timestamp'];?>
</td>
								<td><?php echo $_smarty_tpl->tpl_vars['item']->value['message'];?>
</td>
							</tr>
						<?php } ?>
						<?php }else{ ?>
							<tr>
								<td colspan="3"><?php echo $_smarty_tpl->getConfigVariable('nologs');?>
</td>
							</tr>
						<?php }?>
					   </tbody>
					</table>
					  <div id="tablefooter" style="display:none;">
						<div id="tablenav">
						  <div>
							<img src="layouts/images/icons/first.gif" alt="First Page" onclick="sorter.move(-1,true)" />
							<img src="layouts/images/icons/prev.gif" alt="First Page" onclick="sorter.move(-1)" />
							<img src="layouts/images/icons/next.gif" alt="First Page" onclick="sorter.move(1)" />
							<img src="layouts/images/icons/last.gif" alt="Last Page" onclick="sorter.move(1,true)" />
						  </div>
						  <div>
							<select id="pagedropdown"></select>
						  </div>
						  <div class="page">
							<a href="javascript:sorter.showall()"><?php echo $_smarty_tpl->getConfigVariable('see_all');?>
</a>
						  </div>
						</div>
						<div id="tablelocation">
						  <div>
							<select onchange="sorter.size(this.value)">
							  <option value="5">5</option>
							  <option value="10" selected="selected">10</option>
							  <option value="20">20</option>
							  <option value="50">50</option>
							  <option value="100">100</option>
							</select>
							<span><?php echo $_smarty_tpl->getConfigVariable('entries_p_site');?>
</span>
						  </div>
						  <div class="page"><?php echo $_smarty_tpl->getConfigVariable('site');?>
 <span id="currentpage"></span> <?php echo $_smarty_tpl->getConfigVariable('from');?>
 <span id="totalpages"></span></div>
							</div>
						</div>
					</div>

				</div>
			</div>

		</article>

    <script src="http://api.jquery.com/scripts/events.js"></script>

<script type="text/javascript">
$("#target").keypress(function(event) {
  if ( event.which == 13 ) {
     alert("test");
   }
   xTriggered++;
   var msg = "Handler for .keypress() called " + xTriggered + " time(s).";
  $.print( msg, "html" );
  $.print( event );
});
function sendMessage()
{
     $.ajax({
          type: "POST",
          url: "_modules/home/shoutbox.php",      
          async: false,
          data: "message="+$(".myMessage").val(),
           success: function(msg){
                refreshChat();
                $(".myMessage").val("");
           }
      });
}
function refreshChat()
{
      $.ajax({
          type: "POST",
          url: "_modules/home/shoutbox.php",
           success: function(msg){
                $("#shoutbox").html(msg);
           }
      });
}
window.setInterval("refreshChat()",1000);
</script>
      
<script>
$("#myMessage").keypress(function(event) {
  if ( event.which == 13 ) {
      alert("enter gedrückt!");
     event.preventDefault();
   }
});

</script>
 
<article class="module width_full">
    <header><h3><?php echo $_smarty_tpl->getConfigVariable('shoutbox');?>
</h3></header>
    <div class="message_list">
        <div class="module_content" style="margin:10px 4px !important;" id="shoutbox">
        </div>
    </div>
    <footer>
     <div class="post_message">
      <input type="text" value="<?php echo $_smarty_tpl->getConfigVariable('message');?>
" class="myMessage" id="myMessage" onfocus="if(!this._haschanged){this.value=''};this._haschanged=true;">
      <input type="submit" class="alt_btn" value="<?php echo $_smarty_tpl->getConfigVariable('submit');?>
" onclick="sendMessage();">
     </div>
    </footer>
</article>

      
<script>
$("#myMessage").keypress(function(event) {
  if ( event.which == 13 ) {
      sendMessage();
   }
});


    var sorter = new TINY.table.sorter('sorter','table',{
      headclass:'head',
      ascclass:'asc',
      descclass:'desc',
      evenclass:'evenrow',
      oddclass:'oddrow',
      evenselclass:'evenselected',
      oddselclass:'oddselected',
      paginate:true,
      size:10,
      colddid:'columns',
      currentid:'currentpage',
      totalid:'totalpages',
      startingrecid:'startrecord',
      endingrecid:'endrecord',
      totalrecid:'totalrecords',
      hoverid:'selectedrow',
      pageddid:'pagedropdown',
      navid:'tablenav',
      sortcolumn:1,
      sortdir:1,
      init:true
    });
    </script>
    <?php }} ?>